<?php
/**
 * Invision Power Board
 * Action controller for admin page
 */

class action_settings
{
	var $install;
	
	function action_settings( & $install )
	{
		$this->install =& $install;
	}
	
	function run()
	{
		/* Check input? */
		if( $this->install->mainClass->input['sub'] == 'check' )
		{			
				/* Save Form Data */
				$this->install->saved_data['del'] = $this->install->mainClass->input['del'];
				$this->install->saved_data['edit'] = $this->install->mainClass->input['edit'];
				$this->install->saved_data['rename'] = $this->install->mainClass->input['rename'];
				$this->install->saved_data['copy'] = $this->install->mainClass->input['copy'];
				$this->install->saved_data['move'] = $this->install->mainClass->input['move'];
				$this->install->saved_data['upload'] = $this->install->mainClass->input['upload'];

				/* Next Action */
			$this->install->template->page_current = 'admin';
			$this->install->mainClass->input['sub'] = '';
			require_once( INS_ROOT_PATH . 'core/actions/admin.php' );	
			$action = new action_admin( $this->install );
			$action->run();
			return;		
		}

		/* Output */
		$this->install->template->append( $this->install->template->settings_page() );		
		$this->install->template->next_action = '?p=settings&sub=check';
	}
}

?>